home *** CD-ROM | disk | FTP | other *** search
/ Amiga Collections: Taifun / Taifun 009 (1987-02-15)(Ossowski, Stefan)(DE)(PD).zip / Taifun 009 (1987-02-15)(Ossowski, Stefan)(DE)(PD).adf / HackIconII_Source / HackIcon.h < prev    next >
C/C++ Source or Header  |  1987-03-04  |  3KB  |  110 lines

  1. /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *\
  2. * |_o_o|\\ Copyright (c) 1987 The Software Distillery.  All Rights Reserved *
  3. * |. o.| ||          Written by Doug Walker                                 *
  4. * | .  | ||          The Software Distillery                                *
  5. * | o  | ||          235 Trillingham Lane                                   *
  6. * |  . |//           Cary, NC 27511                                         *
  7. * ======             BBS:(919)-471-6436                                     *
  8. \* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
  9. #define I_REV 29
  10. #define G_REV 29
  11.  
  12. #define CTSIZ  16    /* Color table size */
  13. #define IWIDTH  8    /* # of pixels wide */
  14. #define IHEIGHT 8    /* # of pixels high */
  15. #define IDEPTH  4    /* # of bitplanes   */
  16. #define ILENGTH (IHEIGHT * IDEPTH)  /* Size of one icon's image data */
  17.  
  18. #define SWIDTH  640
  19. #define SHEIGHT 200
  20. #define SDEPTH    4
  21.  
  22. #define IMXLEFT    6
  23. #define IMYTOP    12
  24. #define IMXSKIP   20
  25. #define IMYSKIP   23
  26.  
  27. #define EDXLEFT   36
  28. #define EDYTOP    20
  29. #define ELWIDTH    7
  30. #define ELHEIGHT   7
  31. #define EDWIDTH   (ELWIDTH*IWIDTH)
  32. #define EDHEIGHT  (ELHEIGHT*IHEIGHT)
  33.  
  34. #define PLXLEFT   (EDXLEFT+EDWIDTH+4)
  35. #define PLYTOP    EDYTOP
  36. #define PLXWIDTH  14
  37. #define PLYHEIGHT 7
  38.  
  39. #if 0
  40. #define IMNCOLS ((int)(SWIDTH-2*IMXLEFT)/IMXSKIP)
  41. #else
  42. #define IMNCOLS 32
  43. #endif
  44.  
  45. /* I{X,Y}CALC(num) calculates the {x,y}-pos of the 'num'th icon */
  46. #define IXCALC(num) (IMXLEFT+(num%IMNCOLS)*IMXSKIP)
  47. #define IYCALC(num) (IMYTOP+((int)(num/IMNCOLS))*IMYSKIP)
  48.  
  49. #define CESWIDTH  (PLXLEFT+2*PLXWIDTH+22)
  50. #define CESHEIGHT (EDYTOP+EDHEIGHT+10)
  51.  
  52. #define MAXFONTS 2
  53.  
  54.  
  55. /* Iconfont FLAGS bits */
  56. #define CHANGED 1   /* The font has changed */
  57.  
  58. struct iconfont
  59. {
  60.    char filename[50];                  /* Name of file this font came from */
  61.    int flags;                          /* Bit flags, see above             */
  62.    unsigned char firstchar;            /* First char in the font           */
  63.    unsigned char lastchar;             /* Last char in the font            */
  64.    USHORT colormap[CTSIZ];             /* Color map of this font           */
  65.    struct Image images[256];           /* Image structures                 */
  66.    USHORT idata[256*ILENGTH]; /* Actual image data                */
  67. };
  68.  
  69. #define M_LOAD     0
  70. #define M_SAVE     1
  71. #define M_SAVEAS   2
  72. #define M_COLORS   3
  73. #define M_ALTFONT  4
  74. #define M_COPY     5
  75. #define M_MCOPY    6
  76. #define M_QUIT     7
  77.  
  78. #define ME_SAVE    0
  79. #define ME_RESET   1
  80. #define ME_QUIT    2
  81.  
  82. #define ME_FLIP    0  /* Edit menu first item - FLIP*/
  83. #define ME_XFLIP   0     /* Subitems - X and Y*/
  84. #define ME_YFLIP   1
  85.  
  86. #define ME_ROTATE  1  /* Edit menu second item - ROTATE */
  87. #define ME_POSROT  0     /* Subitems - +90, -90, 180 */
  88. #define ME_NEGROT  1
  89. #define ME_180ROT  2
  90.  
  91. #define ME_SHIFT   2  /* Edit menu third item - SHIFT */
  92. #define ME_LSHIFT  0     /* Subitems - LEFT, RIGHT, UP, DOWN */
  93. #define ME_RSHIFT  1
  94. #define ME_USHIFT  2
  95. #define ME_DSHIFT  3
  96.  
  97. #define MC_ALTFONT  0
  98. #define MC_CANCEL   1
  99.  
  100. #define MC_ORGCOL   0
  101. #define MC_ALTCOL   1
  102.  
  103. /* 0-15 are reserved for color gadgets */
  104. #define G_RED     16
  105. #define G_GREEN   17
  106. #define G_BLUE    18
  107. #define G_RSTR    19
  108. #define G_ROK     20
  109. #define G_RCANCEL 21
  110.